package com.xiaolin.mybatis.mapper;

import com.xiaolin.mybatis.model.User;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;

import java.util.List;

/**
 * @ClassName UserMapper
 * @Description TODO
 * @Detail detail
 * @Author MyPC
 * @Date 2020/11/7
 * @Version 1.0
 */
public interface UserMapper {
    //使用xml配置SQL语句
    User getById(Integer id);
    //使用注解配置SQL语句
    @Select("select * from user")
    List<User> getList();
}
